#include "doublespinbox.h"
#include "doublespinboxplugin.h"

#include <QtPlugin>

DoubleSpinBoxPlugin::DoubleSpinBoxPlugin(QObject *parent)
    : QObject(parent)
{
    m_initialized = false;
}

void DoubleSpinBoxPlugin::initialize(QDesignerFormEditorInterface * /* core */)
{
    if (m_initialized)
        return;

    // Add extension registrations, etc. here

    m_initialized = true;
}

bool DoubleSpinBoxPlugin::isInitialized() const
{
    return m_initialized;
}

QWidget *DoubleSpinBoxPlugin::createWidget(QWidget *parent)
{
    return new DoubleSpinBox(parent);
}

QString DoubleSpinBoxPlugin::name() const
{
    return QLatin1String("DoubleSpinBox");
}

QString DoubleSpinBoxPlugin::group() const
{
    return QLatin1String("");
}

QIcon DoubleSpinBoxPlugin::icon() const
{
    return QIcon(QLatin1String(":/icon.png"));
}

QString DoubleSpinBoxPlugin::toolTip() const
{
    return QLatin1String("");
}

QString DoubleSpinBoxPlugin::whatsThis() const
{
    return QLatin1String("");
}

bool DoubleSpinBoxPlugin::isContainer() const
{
    return false;
}

QString DoubleSpinBoxPlugin::domXml() const
{
    return QLatin1String("<widget class=\"DoubleSpinBox\" name=\"doubleSpinBox\">\n</widget>\n");
}

QString DoubleSpinBoxPlugin::includeFile() const
{
    return QLatin1String("doublespinbox.h");
}
#if QT_VERSION < 0x050000
Q_EXPORT_PLUGIN2(doublespinboxplugin, DoubleSpinBoxPlugin)
#endif // QT_VERSION < 0x050000
